<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <link rel="StyleSheet" href="../css/jpetstore.css" type="text/css" media="screen"/>
</head>
<body>
<div th:replace="common/top"></div>
    <div id="Content">
        <div id="BackLink">
            <a th:href="@{/catalog/viewCategory?categoryId=}+${product.categoryId}"> Return to
                <label th:text="${product.categoryId}">Category <ID></ID></label>
            </a>
        </div>

        <div id="Catalog">

            <h2 th:text="${product.name}">Product Name</h2>

            <table>
                <tr>
                    <th>Item ID</th>
                    <th>Product ID</th>
                    <th>Description</th>
                    <th>List Price</th>
                    <th>&nbsp;</th>
                </tr>

                <tr th:each="item:${itemList}">
                    <td><a th:href="@{/catalog/viewItem?itemId=}+${item.itemId}" th:text="${item.itemId}"> Item ID</a></td>
                    <td th:text="${item.product.productId}">Product ID</td>
                    <td th:text="${item.attribute1}+${item.attribute2}+${item.attribute3}+${item.attribute4}+${item.attribute5}+${item.productId}">Item Atibute</td>
                    <td th:text="${item.listPrice}">Item ListPrice</td>
                    <td><a th:href="'/cart/addItemToCart?workingItemId=' + ${item.itemId}" class="Button">Add to Cart</a> </td>
                </tr>
                <!--<c:forEach var="item" items="${sessionScope.itemList}">
                    <tr>
                        <td>
                            <a href="viewItem?itemId=${item.itemId}">${item.itemId}</a>
                        </td>
                        <td>${item.product.productId}</td>
                        <td>
                            ${item.attribute1} ${item.attribute2} ${item.attribute3}
                            ${item.attribute4} ${item.attribute5} ${sessionScope.product.name}
                        </td>
                        <td><fmt:formatNumber value="${item.listPrice}" pattern="$#,##0.00" />
                        </td>
                        <td>
                            <a class="Button", href="addItemToCart?workingItemId=${item.itemId}">Add to Cart</a>
                        </td>
                    </tr>
                </c:forEach>-->
                <tr>
                    <td>
                    </td>
                </tr>
            </table>

        </div>
    </div>
<div th:replace="common/bottom"></div>
</body>
</html>